const path = require('path')
const resolve = dir => path.join(__dirname, dir)
const BASE_URL = process.env.NODE_ENV === 'production' ? '/' : '/'
const { defineConfig } = require('@vue/cli-service')
module.exports = defineConfig({
  // 保存的时候是否检查
  lintOnSave: false,
  publicPath: BASE_URL,
  chainWebpack: config => {
    config.resolve.alias
      .set('@', resolve('src'))
      .set('@a', resolve('src/assets'))
      .set('@v', resolve('src/views'))
      .set('@c', resolve('src/components'))
      .set('@lib', resolve('src/lib'))
  },
  // 打包时不生成 .map 文件
  productionSourceMap: false,
  transpileDependencies: true
})
